{include file="admin@Public/_header" /}
   
        <div class="row">
            <div class="col-sm-12">
                <div class="ibox float-e-margins">
                    <div class="ibox-title">
                        <h5>添加模板</h5>
                        
                    </div>
                    <div class="ibox-content">
                        <form class="form-horizontal m-t" id="commentForm" action="{:url('add')}" method="post">
                             <div class="form-group">
                                <label class="col-sm-3 control-label">模板：</label>
                                <div class="col-sm-5">
                                       
                                        <input type="file" name="file_upload" id="file_upload" style="display: block;position: absolute;right: 20px;top:2px;background-color: red;padding: 3px;" >
                                        
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
              
            </div>
          
        </div>
{include file="admin@Public/_footer" /}
<script src="__ASSETS__/plugins/uploadify/jquery.uploadify.min.js"></script>
<link rel="stylesheet" href="__ASSETS__/plugins/uploadify/uploadify.css">
<script>
$(function() {
    var uploadUrl = "{:url('Template/add')}";
    $('#file_upload').uploadify({
        'debug'    : true,
        'swf'      : '__ASSETS__/plugins/uploadify/uploadify.swf',
        'uploader' : uploadUrl,
        'onUploadSuccess':function(file, data, response){
            if(data == 1){
                  sweetAlert('上传成功')  
            }else{
                sweetAlert(data)
            }
        }
        // Put your options here
    });
});
</script>
